<?php

//echo 'ini halaman add AR Object';
//echo br(2);

if (isset($message)) {
    echo $message;
    br(2);
}

switch ($obj_view) {
    case 0:
        echo 'Kapasitas objek penuh. Hapus dahulu objek yang sudah ada.';
        break;

    case 1:
        echo 'Silakan masukkan data objek AR yang ingin ditambahkan.';
        echo br(2);
        echo form_open_multipart('object/add_submit/' . $poi_id);
        echo form_label('File-1');
        ?>
        <input type="file" name="userfile" size="20" />
        <?php

        echo br(1);
        echo form_hidden('filename', 'file1');
        echo form_submit('upload', 'Upload');
        echo form_close();
        break;

    case 2:
        echo 'Silakan masukkan data objek AR yang ingin ditambahkan.';
        echo br(2);
        echo form_open_multipart('object/add_submit/' . $poi_id);
        echo form_label('File-2');
        ?>
        <input type="file" name="userfile" size="20" />
        <?php

        echo br(1);
        echo form_hidden('filename', 'file2');
        echo form_submit('upload', 'Upload');
        echo form_close();
        break;

    case 3:
        echo 'Silakan masukkan data objek AR yang ingin ditambahkan.';
        echo br(2);
        echo form_open_multipart('object/add_submit/' . $poi_id);
        echo form_label('File-1');
        ?>
        <input type="file" name="userfile" size="20" />
        <?php
        echo br(1);
        echo form_hidden('filename', 'file1');
        echo form_submit('upload', 'Upload');
        echo form_close();
        
        echo br(3);
        
        echo form_open_multipart('object/add_submit/' . $poi_id);
        echo form_label('File-2');
        ?>
        <input type="file" name="userfile" size="20" />
        <?php
        echo br(1);
        echo form_hidden('filename', 'file2');
        echo form_submit('upload', 'Upload');
        echo form_close();
        break;

    default:
        break;
}

echo br(2);
echo anchor('/home', 'Home');
echo br(1);
echo anchor('/login/logout', 'Logout');
?>